<?php 


setcookie('username','wuqingjia',time()+86400,'/');





echo $_COOKIE['username'].$_COOKIE['sh'];



$arr=['username'=>'wuqingjia','sex'=>'nv'];
// $arr=serialize($arr);

// setcookie('name',$arr);



$arr = json_encode($arr,true);

setcookie('name',$arr)

 ?>